#pragma once
#include <windows.h>

class CTimer
{
    long m_ticksPerSecond;
    long m_currentTime;
    long m_lastTime;
    long m_lastFPSUpdate;
    long m_FPSUpdateInterval;
    unsigned int m_numFrames;
    float m_runningTime;
    float m_timeElapsed;
    float m_fps;
    bool  m_timerStopped;

public:
    CTimer();
    ~CTimer();
    
    // Methods
    void StartTimer(void);
    void StopTimer(void);
    void UpdateTimer(void);
    
    // Accessors
    float GetFPS(void) const { return m_fps; }
    float GetElapsedTime(void) const { return m_timeElapsed; }
    float GetRunningTime(void) const { return m_runningTime; }
    bool IsStopped(void) const { return m_timerStopped; }

};
